package com.okcl.manage.domain;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.okcl.common.annotation.Excel;
import com.okcl.common.core.domain.BaseEntity;
import lombok.Data;

import java.util.Date;

/**
 * 借阅记录对象 tb_borrow_record
 *
 * @author Mike
 * @date 2025-05-15
 */
@Data
public class BorrowRecord extends BaseEntity {
    private static final long serialVersionUID = 1L;

    /**
     * 借阅记录ID
     */
    private Long id;

    /**
     * 用户ID（外键）
     */
    @Excel(name = "用户ID", readConverterExp = "外=键")
    private Long userId;

    /**
     * 书籍ID（外键）
     */
    @Excel(name = "书籍ID", readConverterExp = "外=键")
    private Long bookId;

    /**
     * 借阅日期
     */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "借阅日期", width = 30, dateFormat = "yyyy-MM-dd")
    private Date borrowDate;

    /**
     * 应还日期
     */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "应还日期", width = 30, dateFormat = "yyyy-MM-dd")
    private Date dueDate;

    /**
     * 实际归还日期
     */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "实际归还日期", width = 30, dateFormat = "yyyy-MM-dd")
    private Date returnDate;


}
